import json
import requests

class Requests_Util:
    session = requests.session()
    def send_request(self,method,url,header,data):
        method = str(method).lower()
        if method == 'get':
            req = Requests_Util.session.request(method=method,url=url,headers=header,params=data)
        else:
            data = json.dumps(data)
            req = Requests_Util.session.request(method=method, url=url, headers=header, data=data)
        return req.text
if __name__ == '__main__':
    Requests_Util().send_request()
